FileSearch![]() ![]() ![]() |
Represents a single file search criterion. Search criteria are listed in the Advanced Find dialog box (File menu, Open command, Advanced Find button). The PropertyTest object is a member of the PropertyTests collection.
Use PropertyTests(index), where index is the index number, to return a single PropertyTest object. The following example displays all the search criteria for the first property test in the PropertyTests collection.
With Application.FileSearch.PropertyTests(1)
myString = "This is the search criteria: " _
& " The name is: " & .Name & ". The condition is: " _
& .Condition
If .Value <> "" Then
myString = myString & ". The value is: " & .Value
If .SecondValue <> "" Then
myString = myString _
& ". The second value is: " _
& .SecondValue & ", and the connector is" _
& .Connector
End If
End If
MsgBox myString
End With